[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
SHELL BEXP,VAR,SEXP1,SEXP2
Function
Shell out to a program or batch file.
Syntax
SHELL viacc,retcode,prog,cmds
viacc - A boolean expression with value TRUE if the shell should
be made via COMMAND.COM; FALSE if it should be shelled to
directly.
retcode - A variable in which to store the return code.
prog - A string expression with the file name to shell to.
cmds - A string expression with any arguments to pass to prog.
(NOTE: If viacc is TRUE, the value assigned to retcode will be the
return code of COMMAND.COM, not prog)
Remarks
You may have have need to run a COM, EXE or BAT file from your PPE. You
may need to do this to simulate running a DOOR or to access some service
not normally available from PCBoard or PPL. This function will allow
you to do that. If the viacc parameter is TRUE (you want COMMAND.COM to
load the specified file) then your PATH environment variable will be
searched for prog if it isn't in the current directory or isn't fully
qualified (path and extension) as though you had entered it on the
command line. If viacc is FALSE then you must specify the path and
extension of the program to run. Additionally, the retcode variable
will only be meaningful if viacc is FALSE.
Examples
INTEGER rc
SHELL TRUE,rc,"DOOR",""
INTEGER rc
STRING p,c
LET p = "DOORWAY.EXE"
LET c = "com2 /v:dO /m:600 /g:on /o: /k:v0 /x: /c:dos"
SHELL FALSE,rc,p,c
See Also:
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson